<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>登录</title>
    <script>
        window.onload=function () {
            var Ajax=new XMLHttpRequest();
            Ajax.open('post','http://localhost:8080/web_demo/flowerShop.html',true);
            Ajax.onreadystatechange=function () {
                if (Ajax.readyState==4&&Ajax.status==200){
                    var result=Ajax.responseText;
                    var obj=JSON.parse(result);
                    document.body.innerHTML=obj.name;
                }
            }
        }
    </script>
</head>
<body>
<h1>登录</h1>
<form action="finsd" method="post">
    账号：<input type="text" name="username"/><br><br>
    密码：<input type="password" name="pass"/><br><br>
    <input type="button" value="登录"/>
    <input type="submit" value="不登录也可以"/>
</form>
</body>
</html>